package com.health.tablebean;

import java.io.StringReader;
import java.sql.Clob;
import java.sql.PreparedStatement;
import java.util.Date;

import android.database.SQLException;
import net.tsz.afinal.annotation.sqlite.Id;
import net.tsz.afinal.annotation.sqlite.Table;

/**
 * @author Administrator 心电图

 *
 */
@Table(name="RH_ELECTROCARDIO")
public class RH_ELECTROCARDIO {
	/** 编号 */
	@Id(column="ID")	
	private int ID;
	/** 身份证号 */
	private String IDCARD;
	/** 用户编号 */
	private String USERID;
	/** 设备串号 */
	private String DEVICE_SERIAL;
	/** 是否报警 */
	private String F_ISALERT;
	/** 建议 */
	private String F_EVALUATION;
	/** 算法类型：uu单导心电six六参数,爱得康six_dev，理邦AnnotatedECG */
	private String ALGORITHM_TYPE;
	/** 心电图导联 */
	private String DAOLIAN;
	/** 心电图增益 */
	private int ZENGYI;
	/** 心电图速率 */
	private int SULV;
	/** 心电图 */
	private Clob F_ELECTROCARDIO;
	/** 体检编号 */
	private String PHYSICALID;
	/** 更新人 */
	private String UPDATER;
	/** 更新日期 */
	private Date UPDATEDATE;
	/** 创建日期 */
	private Date CREATEDATE;
	/** 创建人 */
	private String CREATER;
	/** 检查日期 */
	private Date F_DATETIME_CURRENT;

	public int getID() {
		return ID;
	}

	public void setID(int iD) {
		ID = iD;
	}

	public String getIDCARD() {
		return IDCARD;
	}

	public void setIDCARD(String iDCARD) {
		IDCARD = iDCARD;
	}

	public String getUSERID() {
		return USERID;
	}

	public void setUSERID(String uSERID) {
		USERID = uSERID;
	}

	public String getDEVICE_SERIAL() {
		return DEVICE_SERIAL;
	}

	public void setDEVICE_SERIAL(String dEVICE_SERIAL) {
		DEVICE_SERIAL = dEVICE_SERIAL;
	}

	public String getF_ISALERT() {
		return F_ISALERT;
	}

	public void setF_ISALERT(String f_ISALERT) {
		F_ISALERT = f_ISALERT;
	}

	public String getF_EVALUATION() {
		return F_EVALUATION;
	}

	public void setF_EVALUATION(String f_EVALUATION) {
		F_EVALUATION = f_EVALUATION;
	}

	public String getALGORITHM_TYPE() {
		return ALGORITHM_TYPE;
	}

	public void setALGORITHM_TYPE(String aLGORITHM_TYPE) {
		ALGORITHM_TYPE = aLGORITHM_TYPE;
	}

	public String getDAOLIAN() {
		return DAOLIAN;
	}

	public void setDAOLIAN(String dAOLIAN) {
		DAOLIAN = dAOLIAN;
	}

	public int getZENGYI() {
		return ZENGYI;
	}

	public void setZENGYI(int zENGYI) {
		ZENGYI = zENGYI;
	}

	public int getSULV() {
		return SULV;
	}

	public void setSULV(int sULV) {
		SULV = sULV;
	}

	public Clob getF_ELECTROCARDIO() {
		return F_ELECTROCARDIO;
	}

	public void setF_ELECTROCARDIO(Clob f_ELECTROCARDIO) {
		F_ELECTROCARDIO = f_ELECTROCARDIO;
	}

	public String getPHYSICALID() {
		return PHYSICALID;
	}

	public void setPHYSICALID(String pHYSICALID) {
		PHYSICALID = pHYSICALID;
	}

	public String getCREATER() {
		return CREATER;
	}

	public void setCREATER(String cREATER) {
		CREATER = cREATER;
	}

	public String getUPDATER() {
		return UPDATER;
	}

	public void setUPDATER(String uPDATER) {
		UPDATER = uPDATER;
	}

	public Date getUPDATEDATE() {
		return UPDATEDATE;
	}

	public void setUPDATEDATE(Date uPDATEDATE) {
		UPDATEDATE = uPDATEDATE;
	}

	public Date getCREATEDATE() {
		return CREATEDATE;
	}

	public void setCREATEDATE(Date cREATEDATE) {
		CREATEDATE = cREATEDATE;
	}

	public Date getF_DATETIME_CURRENT() {
		return F_DATETIME_CURRENT;
	}

	public void setF_DATETIME_CURRENT(Date f_DATETIME_CURRENT) {
		F_DATETIME_CURRENT = f_DATETIME_CURRENT;
	}

	public final static String getValueFromClob(Clob clob) throws SQLException {  
        String value = null;  
  
        if (clob != null) {  
            int size;
			try {
				size = (int) clob.length();
				value = clob.getSubString(1, size);  
			} catch (java.sql.SQLException e) {
				// TODO Auto-generated catch block
				e.printStackTrace();
			}  
        }  
  
        return value;  
    }  
  
    public final static void setClobParameter(PreparedStatement ps, int i,  
            String parameter) throws SQLException {  
  
        StringReader reader = new StringReader(parameter);  
        try {
			ps.setCharacterStream(i, reader, parameter.length());
		} catch (java.sql.SQLException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		}  
    }  

}
